<%--
  首个报表 二阶
  User: Ivan
  Date: 2019-09-03 12:47
--%>
<style type="text/css">
tr, th, td {
    text-align: center;
}
</style>

<div class="bjui-pageHeader">
    <form id="pagerForm" data-toggle="ajaxsearch" action="${request.getContextPath()}/FirstReport/firstReportDetail" method="post">
        <div class="bjui-searchBar">
            <g:hiddenField name="SYS_QUERY_NAME" value="${SYS_QUERY_NAME}"/>
            <g:hiddenField name="EXPORT_CONTENT_NAME" value="Excel" />
            <g:hiddenField name="startTime" value="${startTime}" />
            <g:hiddenField name="endTime" value="${endTime}" />
            <g:hiddenField name="dgStepName" value="${dgStepName}" />
            <g:hiddenField name="dgStepDesc" value="${dgStepDesc}" />
            <g:hiddenField name="clazz" value="${clazz}" />
            <button type="submit" class="btn-default" data-icon="search">刷新</button>&nbsp;
            <button type="button" class="btn-blue"
                    onclick="javascript:bjuiExportExl('#pagerForm', '${request.getContextPath()}/Base/exportExcel')"
                    data-icon="file-excel-o" title="导出Excel">导出</button>
        </div>
    </form>
</div>

<div class="bjui-pageContent tableContent">
    <g:if test="${reportList.size() > 0}">
        <table class="table table-bordered table-hover table-striped table-top" data-selected-multi="true" data-toggle="tablefixed" data-width="200%">
            <thead>
            <tr>
                <th width="50">NO.</th>
                <g:each in="${tableHeadList}" status="i" var="headInstance">
                    <g:if test="${headInstance != 'RN'}">
                        <th>${headInstance}</th>
                    </g:if>
                </g:each>
            </tr>
            </thead>
            <tbody>
            <g:each in="${reportList}" status="i" var="dataInstance">
                <tr data-id="data">
                    <td>${dataInstance.RN}</td>
                    <g:each in="${tableHeadList}" status="j" var="headInstance">
                        <g:if test="${headInstance != 'RN'}">
                            <td>${dataInstance[headInstance]}</td>
                        </g:if>
                    </g:each>
                </tr>
            </g:each>
            </tbody>
        </table>
    </g:if>
    <g:else>
        <g:render template="../template/emptyPanel"/>
    </g:else>
</div>
<g:render template="../template/pagination"/>